<?php

namespace App\Models\Finance;

use Illuminate\Database\Eloquent\Model;

class Template extends Model
{
	/**
	 * 定义可批量填充字段
	 *
	 * @var array
	 * Date: 19/03/2018
	 * @author George
	 */
	protected $guarded = ['id'];

	/**
	 * 获取模板条件
	 *
	 * Date: 2018/6/11
	 * @author George
	 * @return \Illuminate\Database\Eloquent\Relations\HasMany
	 */
	public function conditions()
	{
		return $this->hasMany(Condition::class, 'template_id', 'id');
	}
}
